<template>
	<view class="carousel">
		<view style="margin: 40upx 38upx;">
			<u-parse :content="context"></u-parse>
			<!-- <rich-text class="test" :nodes="context"></rich-text> -->
		</view>
	</view>
</template>

<script>
	import $H from "@/common/js/request.js"
	export default {
		data() {
			return {
				context: ''
			};
		},
		onLoad(opt) {
			$H.post('index/policy', {
				type: opt.name
			}, {
				token: false
			}).then(res => {
				if (res.code == 1) {
					this.context = res.data.content
					uni.setNavigationBarTitle({
						title:res.data.title
					})
				} else {
					uni.showToast({
						title: res.msg,
						icon: 'none',
						duration: 2000
					});
				}
			})
		},
		methods:{
		}
	}
</script>

<style>
	page{
		background: #fff;
	}
	.carousel{
		width: 100%;
	}
</style>
